﻿
@{
    ViewData["Title"] = "调拨单";
}

<style type="text/css">
    form {
        margin: 0;
    }

    textarea {
        display: block;
        width: 316px;
        margin-left: 702px;
    }

    .need {
        FONT-STYLE: normal;
        FONT-FAMILY: 微软雅黑;
        FONT-SIZE: 13px;
        TEXT-DECORATION: none;
        width: 75px;
    }

    .yincang {
        display: none;
    }

    .auto-style21 {
        width: 100px;
    }

    #totalAccunt {
        width: 79px;
    }
</style>

<form id="mainForm" name="mainForm" method="post" runat="server">
    <div class="mini-toolbar" style="border-bottom: 0; padding: 0px; padding-left: 10px;">
        <table style="width: 100%">
            <tr>
                <td>
                    <label class="need">调拨单号：</label>
                    <input id="whaCode" name="whaCode" class="mini-textbox" readonly="true" />
                </td>
                <td>
                    <label class="need">调拨状态：</label>
                    <input class="mini-combobox" id="Status" name="Statusname" textField="name" valueField="id" data="[{id:'0',name:'保存'},{id:'1',name:'调出途中-提交'},{id:'2',name:'调入确认'},{id:'3',name:'核准'}]" showNullItem="true" nullitemtext="请选择..." value="0" />
                </td>

                <td>
                    <label class="need">调出时间：</label>
                    <input id="PlanDate" name="PlanDate" class="mini-datepicker" />
                </td>
                <td>
                    <a class="mini-button" style="width: 120px;" iconcls="icon-save" onclick="GetitemCount()">保存</a>
                    <a class="mini-button" style="width: 120px;" iconcls="icon-ok" onclick="chkContinue()">调出确认</a>
                    <a class="mini-button" style="width: 120px;" iconcls="icon-ok" onclick="chkContinue()">调入确认</a>
                    <a class="mini-button" style="width: 120px;" iconcls="icon-ok" onclick="chkContinue()">核准</a>
                    <a class="mini-button" style="width: 120px;" iconcls="icon-print" onclick="chkContinue()">打印</a>
                </td>
            </tr>
            <tr>
                <td>
                    <label class="need">调出仓库：</label>
                    <input id="OutwhID" class="mini-combobox" textfield="whInfo" valuefield="whID" shownullitem="true" allowinput="true" nullitemtext="请选择..." valueFromSelect="true" url="" />
                </td>
                <td>
                    <label class="need">调入仓库：</label>
                    <input id="InwhID" class="mini-combobox" textfield="whInfo" valuefield="whID" shownullitem="true" allowinput="true" nullitemtext="请选择..." valueFromSelect="true" url="" />
                </td>

                <td>
                    <label class="need">调入时间：</label>
                    <input id="PlanDateOut" name="PlanDateOut" class="mini-datepicker" />
                </td>
                <td>
                    <a class="mini-button" style="width: 120px;" iconcls="icon-remove" onclick="GetitemCount()">删除</a>
                    <a class="mini-button" style="width: 120px;" iconcls="icon-no" onclick="chkContinue()">取消调出</a>
                    <a class="mini-button" style="width: 120px;" iconcls="icon-no" onclick="chkContinue()">取消调入</a>
                    <a class="mini-button" style="width: 120px;" iconcls="icon-no" onclick="chkContinue()">取消核准</a>
                </td>
            </tr>
        </table>
    </div>
</form>

<div style="width: 100%;">
    <div id="p1" class="mini-panel" title="调出条码" style="width:500px;height:200px;margin-top: 10px;display: inline-block;">
    </div>
    <div id="p2" class="mini-panel" title="调入条码" style="width:500px;height:200px;margin-top: 10px;display: inline-block;margin-left: 20px;">
    </div>
</div>

<div style="width: 100%">
    <div class="mini-toolbar" style="border-bottom: 0; padding: 0px;">
        <table style="width: 100%;">
            <tr>
                <td>
                    <a class="mini-button" iconcls="icon-add" onclick="addRow()" plain="true" id="bt1">新增电池</a>
                </td>
            </tr>
        </table>
    </div>
</div>

<div class="mini-fit">
    <div id="datagrid1" class="mini-datagrid" allowCellEdit="true" allowCellSelect="true" style="width:100%;height:100%;" sortmode="client" idField="itemId" allowResize="true" url="">
        <div property="columns">
            <div field="whaCode" allowSort="true" width="120" headerAlign="center">
                车型编码
            </div>
            <div field="Preparedby" allowSort="true" width="120" headerAlign="center">
                车型名称
            </div>
            <div field="PreparedTime" allowSort="true" width="120" headerAlign="center">
                车型规格
            </div>
            <div field="Submittedby" allowSort="true" width="120" headerAlign="center">
                调出数量
            </div>
            <div field="SubmissionTime" allowSort="true" width="120" headerAlign="center">
                调入数量
            </div>
            <div field="SubmissionTime" allowSort="true" width="120" headerAlign="center">
                电池编码
            </div>
            <div type="comboboxcolumn" field="SubmissionTime" allowSort="true" width="120" headerAlign="center">
                电池名称
                <input property="editor" class="mini-combobox" style="width:100%;" data="Genders" />
            </div>
            <div field="SubmissionTime" allowSort="true" width="120" headerAlign="center">
                调出数量
                <input property="editor" class="mini-spinner" style="width:100%;" />
            </div>
            <div field="SubmissionTime" allowSort="true" width="120" headerAlign="center">
                调入数量
                <input property="editor" class="mini-spinner" style="width:100%;" />
            </div>
        </div>
    </div>
</div>

<script type="text/javascript">
    mini.parse();
    var p1 = mini.get("p1");
    var p2 = mini.get("p2");
    p1.setButtons([{ html: '<button style="position:relative;top:-4px;">生成调出数量</button>' }]);
    p2.setButtons([{ html: '<button style="position:relative;top:-4px;">生成调入数量</button>' }]);

    var Genders = [{ id: 1, text: '标配信息' }, { id: 0, text: '换配信息' }];

</script>